# 多线程打开小破站
import requests
from threading import Thread
def request__xiaopozhan():
    url = "https://www.bilibili.com/"
    # body = ""
    headres = {
        "User-Agent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:84.0) Gecko/20100101 Firefox/84.0"}
    response = requests.get(url=url,headres=headres)
    print(response)
if __name__ == "__main__":
    print(__name__)
for i in range(10):
    t = Thread(target=request__xiaopozhan)
    t.start()


#多进程
import requests
from multiprocessing import Process
def request__xiaopozhan():
    url = "https://www.bilibili.com/"
    # body = ""
    headres = {
        "User-Agent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:84.0) Gecko/20100101 Firefox/84.0"}
    response = requests.get(url=url,headres=headres)
    print(response)
if __name__ == "__main__":
    print(__name__)
for i in range(10):
    p = Process(target=request__xiaopozhan)
    p.start()